#include "tests.h"
#include <functions.h>
#include <Expr.h>
void testOfSubstitution(const int, const TestX &);

int main() {
	TestX T(0);
	testOfSubstitution(0,T);
}

void testOfSubstitution(const int numberTest, const TestX & T) {
	int nT = 0;
	Expr a("a");
	Expr b("b");
	Expr c("c");
	Expr d("d");
//--- numbers		
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2);
		e.sub(a+2, 1);
		T.test(e, "2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+2);
		e.sub(a, -1);
		T.test(e, "1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+2);
		e.sub(-a, 2);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e((a+5)*(3-a));
		e.sub(a,-3);
		T.test(e,"12",__LINE__, nT);
	}
//--- 
	if (numberTest == ++nT || numberTest == 0) {
		Expr e((2*a+2*(a+b)));
		e.sub(a+b, b);
		T.test(e, "2b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e((a+2*(a+b)));
		e.sub(a+b, b);
		T.test(e, "2b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a-2);
		e.sub(a, b);
		T.test(e, "-2+b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-2);
		e.sub(2,-a);
		T.test(e,"-2",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(20*a);
		e.sub(2*a, 1);
		T.test(e, "10", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(20*a);
		e.sub(2*a, -1);
		T.test(e, "-10", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(20*a);
		e.sub(2*a, b);
		T.test(e, "10b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(20*a);
		e.sub(2*a,-b);
		T.test(e,"-10b",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-20*a);
		e.sub(2*a, 1);
		T.test(e, "-10", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-20*a);
		e.sub(2*a, -1);
		T.test(e, "10", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-20*b);
		e.sub(2*b, a);
		T.test(e, "-10a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-20*b);
		e.sub(2*b,-a);
		T.test(e,"10a",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(0);
		e.sub(2, 1);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(-a, -1);
		T.test(e, "1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(0);
		e.sub(0, 0);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(0);
		e.sub(2, -a);
		T.test(e,"0",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(1);
		e.sub(0, 1);
		T.test(e, "1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4);
		e.sub(0, 0);
		T.test(e, "4", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(40*a);
		e.sub(4*a, 0);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-0);
		e.sub(0, 3);
		T.test(e,"0",__LINE__, nT);
	}
//--- variables
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(a, 1);
		T.test(e, "1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(a, -1);
		T.test(e, "-1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b);
		e.sub(b, a);
		T.test(e, "a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b);
		e.sub(b,-a);
		T.test(e,"-a",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-b);
		e.sub(b, 1);
		T.test(e, "-1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-b);
		e.sub(b, -1);
		T.test(e, "1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-b);
		e.sub(b, a);
		T.test(e, "-a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-b);
		e.sub(b,-a);
		T.test(e,"a",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b);
		e.sub(c, -a);
		T.test(e, "b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b);
		e.sub(b, c);
		T.test(e, "c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b);
		e.sub(-b, a);
		T.test(e, "-a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b);
		e.sub(-b, c);
		T.test(e,"-c",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-b);
		e.sub(c, -b);
		T.test(e, "-b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(0, -1);
		T.test(e, "a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(-a, 0);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-a);
		e.sub(a, 0);
		T.test(e,"0",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-a);
		e.sub(a, -b);
		T.test(e, "b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-a);
		e.sub(-a, b);
		T.test(e, "b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(a, 2);
		T.test(e, "2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(-a, -2);
		T.test(e,"2",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b);
		e.sub(b, a);
		T.test(e, "a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(0, 0);
		T.test(e, "a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(a, 0);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-a);
		e.sub(a, 3);
		T.test(e,"-3",__LINE__, nT);
	}
//--- additions
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(1+a);
		e.sub(b, a);
		T.test(e, "1+a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a);
		e.sub(a, 1+b);
		T.test(e, "1+b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+b);
		e.sub(a, c);
		T.test(e, "b+c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b-a);
		e.sub(a, c);
		T.test(e,"b-c",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(1+a);
		e.sub(a, b);
		T.test(e, "1+b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-1-a);
		e.sub(a, b);
		T.test(e, "-1-b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+b);
		e.sub(a, c);
		T.test(e, "b+c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b-a);
		e.sub(a, c);
		T.test(e,"b-c",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(1+a);
		e.sub(1+b, a);
		T.test(e, "1+a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b+a-1);
		e.sub(b-1, 1+a);
		T.test(e, "1+2a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+b+c-3);
		e.sub(c-3, -b);
		T.test(e, "a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b-a);
		e.sub(a+0, b);
		T.test(e,"0",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(c-a+d+c);
		e.sub(2-a, d);
		T.test(e, "-2+2c+2d", __LINE__, nT);
	}	
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(c-a+d+c+b);
		e.sub(2+a-b,d);
		T.test(e, "2+2c", __LINE__, nT);
	}	
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(c-a+d+c+b);
		e.sub(2+a-b,-d);
		T.test(e, "2+2c+2d", __LINE__, nT);
	}	
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(11+c-a+d+c);
		e.sub(1-a, -10);
		T.test(e, "2c+d", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b+a-1);
		e.sub(b-1, 1+a);
		T.test(e, "1+2a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+b+c-3);
		e.sub(-c+3, -b);
		T.test(e, "a+2b", __LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(c-a+d+c);
		e.sub(c+d, a);
		T.test(e, "c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+b+c-3);
		e.sub(-c+3, -a-b);
		T.test(e, "2a+2b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a+b+c-3);
		e.sub(-c-2, -a-b);
		T.test(e, "-5+2a+2b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b-a);
		e.sub(a+b, b-a);
		T.test(e,"-a+b",__LINE__, nT);
	}
//--- Multiple  & multiplication
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a);
		e.sub(b, a);
		T.test(e, "4a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a);
		e.sub(4*a, 1+b);
		T.test(e, "1+b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a);
		e.sub(a, c);
		T.test(e, "4c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*b);
		e.sub(4*a, 7);
		T.test(e,"7b",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*(-b));
		e.sub(2*a, 7);
		T.test(e,"-14b",__LINE__, nT);
	}
//--- 
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2+c+4*a+3*c);
		e.sub(2+4*c, a);
		T.test(e, "5a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a+b+a+c));
		e.sub(a, (-b)/2);
		T.test(e, "4c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a-b+a+c));
		e.sub(a, b/2);
		T.test(e, "4c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-4*(a+c)+c);
		e.sub(c, -a);
		T.test(e, "-a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a+c+6*d+3*b));
		e.sub(2*d+b, a);
		T.test(e,"16a+4c",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a+2*c+6*d);
		e.sub(a+2*d, -b);
		T.test(e,"a-3b+2c",__LINE__, nT);
	}
//--- 
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2+c+4*a+3*c);
		e.sub(+1-2*c, a);
		T.test(e, "4+2a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a+b+a+c));
		e.sub(a, (-b)/2+c);
		e.expansion();
		T.test(e, "12c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a-b+a+c));
		e.sub(4*a, b/2);
		e.expansion();
		T.test(e, "-3b+4c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-4*(a+c)+c);
		e.sub(c, -2-a);
		T.test(e, "6-a", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a+c+6*d+3*b));
		e.sub(4*(b+c+2*d*3+2*b+a), 0);
		T.test(e,"0",__LINE__, nT);

	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a+2*c+6*d);
		e.sub(0, -b);
		T.test(e,"4a+2c+6d",__LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a+2*c+6+d);
		e.sub(a+2*d, -b);
		T.test(e,"6+3a-b+2c-d",__LINE__,nT);
	}
//--- multiplications
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*a*(b+c)*b);
		e.sub(b, 0);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a*b*(a+c)));
		e.sub(a*b, a+c);
		T.test(e, "4(a+c)^2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*(a*c*(2*(b+d))));
		e.sub(c*a, 1/(b+d));
		T.test(e, "8", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-4*a*b*d);
		e.sub(2*a, c);
		T.test(e, "-2bcd", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*b*c);
		e.sub(2*a*c, 3);
		T.test(e,"6b",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*b*c*a);
		e.sub(-2*a*c, 5/(-b));
		T.test(e,"10",__LINE__, nT);
	}
//--- 
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*a*(b+c)*b);
		e.sub(-b-c, 0);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*a*(b+c)*b);
		e.sub(2*(b+c)*a, 7*b);
		T.test(e, "7b^2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*a*(b+c)*b);
		e.sub(c, b);
		T.test(e, "4ab^2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-4*a*a*b*d);
		e.sub(-2*a, c);
		T.test(e, "-bc^2d", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*b*c*a);
		e.sub(b, 5*(c+a));
		T.test(e,"20ac(a+c)",__LINE__, nT);
	}
//---  powers
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*a*a*b);
		e.sub(a, b);
		T.test(e, "2b^3", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*a*(b+c)*a*b*b);
		e.sub(2*(a^2), 7*(b+c));
		T.test(e, "7b^2(b+c)^2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*(a^(d+c))*b);
		e.sub(-c, d-2);
		T.test(e, "2a^2b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-4*a*a*b*d);
		e.sub(-a, c^5);
		T.test(e, "-4bc^10d", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-4*a*b*c*a);
		e.sub(2*a, c^5);
		T.test(e,"-bc^11",__LINE__, nT);
	}
//--- 
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*a*a*b/(c^4));
		e.sub(c, (b^-2));
		T.test(e, "2a^2b^9", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(8*a*(b+c)*a*(a^2)*b*b);
		e.sub(2*(a^2), b^c);
		T.test(e, "2b^(2+2c)(b+c)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(8*a*(b+c)*a*(a^2)*b*b);
		e.sub(2*(a^2), b+c);
		T.test(e, "2b^2(b+c)^3", __LINE__, nT);

	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(8*a*(b+c)*a*(a^2)*b*b);
		e.sub(2*(a^2), b-c);
		T.test(e, "2b^2(b+c)(b-c)^2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(16*a*(b+c)*a*(a^2)*b*b);
		e.sub(-2*a, 3*(b^(-c)));
		T.test(e, "81b^(2-4c)(b+c)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(a*(b+c)*a*(a^2)*b*b);
		e.sub(-2*a, 3*(b^(-c)));
		T.test(e, "(81/16)b^(2-4c)(b+c)", __LINE__, nT);
	}

	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(16*a*(b+c)*a*a*b*b);
		e.sub(-2*a, 3*(b^(-c)));
		T.test(e, "-54b^(2-3c)(b+c)", __LINE__, nT);
	}

	if (numberTest == ++nT || numberTest == 0) {
		Expr e(-4*a*a*(b^2)*d);
		e.sub(-a, 1/b);
		T.test(e, "-4d", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(a*a*(b^2));
		e.sub(-a, 1/b);
		T.test(e, "1", __LINE__, nT);
	}
//--- 
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(2*(a^7));
		e.sub(a, -2*(b^-7));
		T.test(e, "-256/b^49", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(8*(a^9));
		e.sub(-2*(a^9), b^c);
		T.test(e, "-4b^c", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(a^8);
		e.sub(a^2, b);
		T.test(e, "b^4", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(a^8);
		e.sub(-(a^2), b);
		T.test(e, "b^4", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(a^8);
		e.sub(-(a^2), -b);
		T.test(e, "b^4", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(-(a^8));
		e.sub(-(a^2), b);
		T.test(e, "-(b^4)", __LINE__, nT);
	}
//---
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b^d);
		e.sub(b, 0);
		T.test(e, "0", __LINE__, nT);

		}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b^a);
		e.sub(-a, 1);
		T.test(e, "1/b", __LINE__, nT);

	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(a^c);
		e.sub(a, b^(-c));
		T.test(e, "b^(-(c^2))", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(a^c);
		e.sub(c, 0);
		T.test(e, "1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(b^d);
		e.sub(d, 1);
		T.test(e, "b", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e((-b)^a);
		e.sub(a, 2);
		T.test(e, "b^2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*(a+b)*c);
		e.sub(2/a, d);
		T.test(e,"8c(b+2/d)/d",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*(a+b)*c);
		e.sub(-2/a, d);
		T.test(e,"-8c(b-2/d)/d",__LINE__, nT);
	}
//--- functions
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(1));
		e.sub(b, 0);
		T.test(e, "Sin(1)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(1));
		e.sub(Sin(1), -1);
		T.test(e, "-1", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(Sin(12));
		e.sub(Sin(12), 0);
		T.test(e, "0", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(a));
		e.sub(b, a);
		T.test(e, "Sin(a)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(-1));
		e.sub(Sin(1), -1);
		T.test(e, "Sin(-1)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(Sin(12));
		e.sub(Sin(2), 0);
		T.test(e, "Sin(12)", __LINE__, nT);
	}
//---	
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(a-1));
		e.sub(a, b+2);
		T.test(e, "Sin(1+b)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(-a));
		e.sub(Sin(a), -1);
		T.test(e, "Sin(-a)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(Sin(2*a));
		e.sub(Sin(3*a), 1);
		T.test(e, "Sin(2a)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(a));
		e.sub(-Sin(a), -Cos(-a));
		T.test(e, "Cos(-a)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(a));
		e.sub(Sin(-a), -1);
		T.test(e, "Sin(a)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(Sin(2+a));
		e.sub(Sin(2), 0);
		T.test(e, "Sin(2+a)", __LINE__, nT);
	}
//---	
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(Sin(-2));
		e.sub(Sin(-2), Sin(2));
		T.test(e, "Sin(2)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(3*Sin(2));
		e.sub(2*Sin(2), 1);
		T.test(e, "3/2", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(2+a-b));
		e.sub(Sin(a-b), 2);
		T.test(e, "Sin(2+a-b)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(4*a*(a+b)*c));
		e.sub(2/a, d);
		T.test(e,"Sin(8c(b+2/d)/d)",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*Sin(a+b)*c);
		e.sub(-2*Sin(a+b), d);
		T.test(e,"-2acd",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*Sin(a-b)*c);
		e.sub(-2*Sin(a+b), d);
		T.test(e,"4acSin(a-b)",__LINE__, nT);
	}
//---	
	if (numberTest == ++nT || numberTest == 0) {
 	 	Expr e(Sin(-2)+3*Cos(a));
		e.sub(-Sin(-2), Cos(a));
		T.test(e, "2Cos(a)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(a)+Cos(a));
		e.sub(Sin(a), Sin(b));
		T.test(e, "Cos(a)+Sin(b)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(2+a+Cos(a)-b));
		e.sub(-Cos(a), a-b);
		T.test(e, "Sin(2)", __LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(Sin(4*a*Cos(a+b)*c)^Cos((-a-b)*(-1)));
		e.sub(Cos(a+b), 1/a);
		T.test(e,"Sin(4c)^(1/a)",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*Sin(a+b)*c);
		e.sub(-2*Sin(a+b), 0);
		T.test(e,"0",__LINE__, nT);
	}
	if (numberTest == ++nT || numberTest == 0) {
		Expr e(4*a*Sin(a-b)*c);
		e.sub(-2*Sin(a+b), 0);
		T.test(e,"4acSin(a-b)",__LINE__, nT);
	}
}

